package com.ecfront.pojo;

import java.util.Date;
import java.util.HashSet;
import java.util.Set;

/**
 * 管理员相关属性
 * 
 * @version 1.0
 * @author zhufeng
 */

@SuppressWarnings("unchecked")
public class Admin {

	private int adminId;// 管理员ID
	private String adminName;// 管理员口令
	private String adminPassword;// 管理员密码
	
	private Date lastLoginDate;//最后一次登陆时间
	private Date lastLoginErrorDate;//最后一次错误登陆时间
	private String lastLoginIP;//最后一次登陆的IP
	private String lastLoginErrorIP;//最后一次错误登陆的IP
	
	private int powerId;// 管理员权限
	private Set notes;//管理员发布的公告

	public Admin() {}
	public Admin(Integer adminId) {
		this.adminId = adminId;
	}
	public Admin(Integer adminId, String adminName, String adminPassword,
			Integer powerId, Set notes) {
		this.adminId = adminId;
		this.adminName = adminName;
		this.adminPassword = adminPassword;
		this.powerId = powerId;
		this.notes = notes;
	}
	/**
	 * 返回Admin的ID
	 * @return ID
	 */
	public int getAdminId() {
		return adminId;
	}
	/**
	 * 设置Admin的ID
	 * @param adminId Admin的ID
	 */
	public void setAdminId(int adminId) {
		this.adminId = adminId;
	}
	/**
	 * 返回Admin用帐户
	 * @return Admin用户名
	 */
	public String getAdminName() {
		return adminName;
	}
	/**
	 * 设置Admin的帐户
	 * @param adminName
	 */
	public void setAdminName(String adminName) {
		this.adminName = adminName;
	}
	/**
	 * 返回Admin的密码
	 * @return Admin密码
	 */
	public String getAdminPassword() {
		return adminPassword;
	}
	/**
	 * 设置Admin的密码
	 * @param adminPassword 密码
	 */
	public void setAdminPassword(String adminPassword) {
		this.adminPassword = adminPassword;
	}
	/**
	 * 返回Admin权限
	 * @return 权限ID
	 */
	public int getPowerId() {
		return powerId;
	}
	/**
	 * 设置Admin权限ID
	 * @param powerId 权限ID
	 */
	public void setPowerId(int powerId) {
		this.powerId = powerId;
	}
	/**
	 * 返回所有公告
	 * @return 公告集合
	 */
	public Set getNotes() {
		return this.notes;
	}
	/**
	 * 设置公告
	 * @param notes 公告集合
	 */
	public void setNotes(Set notes) {
		this.notes = notes;
	}
	public Date getLastLoginDate() {
		return lastLoginDate;
	}
	public void setLastLoginDate(Date lastLoginDate) {
		this.lastLoginDate = lastLoginDate;
	}
	public Date getLastLoginErrorDate() {
		return lastLoginErrorDate;
	}
	public void setLastLoginErrorDate(Date lastLoginErrorDate) {
		this.lastLoginErrorDate = lastLoginErrorDate;
	}
	public String getLastLoginIP() {
		return lastLoginIP;
	}
	public void setLastLoginIP(String lastLoginIP) {
		this.lastLoginIP = lastLoginIP;
	}
	public String getLastLoginErrorIP() {
		return lastLoginErrorIP;
	}
	public void setLastLoginErrorIP(String lastLoginErrorIP) {
		this.lastLoginErrorIP = lastLoginErrorIP;
	}
	
}
